<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateReportSettingField extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('t_report_setting_field', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('table_id')->comment('关联表编号');
            $table->string('sum_field')->default(null)->comment('统计字段');
            $table->string('sum_desc')->default(null)->comment('统计字段描述');
            $table->boolean('is_inc')->default(false)->comment('是否是累计字段');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('t_report_setting_field');
    }
}
